package org.naxx.security.expression;

import java.util.List;

import org.naxx.security.function.FunctionType;
import org.naxx.security.model.match.AttributeDesignator;
import org.naxx.security.model.match.ValueHolder;

public interface Node {
	
	/**
	 * Each node in expression tree is either
	 * leaf or non-leaf node. 
	 */
	public enum NodeType {
		/**
		 * Node with no children.
		 */
		LEAF,
		
		/**
		 * Node with at least one child. 
		 */
		NON_LEAF
	}
	
	public String getId();

	public Node getParent();
	
	public List<Node> getChildren();
	
	public NodeType getNodeType();
	
	public ValueHolder getValueHolder();
	
	public FunctionType getFunctionType();
	
	public AttributeDesignator getAttributeDesignator();
	
	public Node getSibling();
}
